package utils;

public enum ResponseCode {
    SUCCESS(100,"操作成功"),

    OK_REGISTER(101,"注册成功！请24小时内打开邮箱，点击邮箱链接地址，进行激活才能使用该账号！"),
    ERROR(200,"操作失败"),

    NOT_ROLE(201,"无角色"),

    NOT_LOGIN(202,"未登录"),
    NOT_USER(203,"不存在该用户"),
    NOT_USER_OR_PASSWORD(204,"没有该用户或密码不对"),
    NOT_PASSWORD(205,"密码不正确"),
    NOT_ACTIVE(206,"用户没有激活"),
    ERROR_DB(207,"数据库异常"),
    ERROR_USERNAME(208,"该用户名已被占用！"),
    ERROR_EMAIL_ADDRESS(209,"您输入的邮箱地址格式不对，注册失败！"),
    ERROR_EMAIL_END(210,"激活邮箱发送失败！"),
    ERROR_PARANS(211,"请求参数不对或类型不对或参数缺失！");

    private int code;
    private String desc;

    ResponseCode(int code,String desc){
        this.code = code;
        this.desc = desc;
    }

    public int getCode(){
        return code;
    }

    public String getDesc(){
        return desc;
    }
}
